
<?php
$jige = 75;
$html = 90;
$wangye = 75;
$js = 55;
$avg = ($html + $wangye + $js)/3;
?>

<?php  
echo "及格线是=$jige</br>";
echo "HTML分数=$html</br>";
echo "网页设计分数=$wangye</br>";
echo "JS分数=$js</br>";
echo "所有分数的平均分=$avg</br>";
echo "分数是否及格：";
?>

<?php 
if ($avg >= $jige) {
    echo "及格";
}else {
    echo "不及格";
}
?>

</br>
</br>
</br>
</br>
<!doctype html>
<html lang="en">
<head>
	<meta charset="UTF-8">
	<title>Document</title>
</head>
<body>
    及格线是=<?php echo "$jige"; ?></br>
    HTML分数=<?php echo "$html"; ?></br>
    网页设计分数=<?php echo "$wangye"; ?></br>
    JS分数=<?php echo "$js"; ?></br>
    所有分数的平均分=<?php echo "$avg"; ?></br>
    分数是否及格：<?php if ($avg >= $jige): ?>
    <span style="color: green">及格</span>
    <?php else :?>
    <span style="color: red">不及格</span>
    <?php endif ; ?>
    
    
</body>
</html>
